import { defineComponent } from 'vue';
import { ElCard, cardProps } from 'element-plus';

const Panel = defineComponent(
  /**
   * @description: 卡片组件
   */

  (props, { attrs, slots }) => {
    return () => (
      <>
        <ElCard {...attrs} {...props} class={`a-panel ${attrs.class || ''}`} v-slots={slots}></ElCard>
        <style jsx>
          {`
            .a-panel {
              --el-card-padding: 10px;
            }
          `}
        </style>
      </>
    );
  },
  {
    props: cardProps
  }
);

export default Panel;
